package ar.edu.um.isa.manager;

import java.util.List;

import ar.edu.um.isa.dao.PublicationDao;
import ar.edu.um.isa.dao.PublicationMysqlDao;
import ar.edu.um.isa.model.Publication;
import ar.edu.um.isa.model.Publisher;

public class MicrobloggingManager {
	
	PublicationDao publicationDao;
	
	public PublicationDao getPublicationDao() {
		return publicationDao;
	}

	public void setPublicationDao(PublicationDao publicationDao) {
		this.publicationDao = publicationDao;
	}

	public void publish(Publication publication){
		// parse publication
		//......
		
		publicationDao.insertPublication(publication);
	}
	
	public List<Publication> findPublicationByPublisher(Publisher publisher){
		return publicationDao.findPublicationByPublisher(publisher);
	}
}
